﻿<!-- #include file="mymin.asp" -->
<%
If Request("submit") <> "" Then

	linkStyle=Request.Form("linkStyle")
	linkAct=Request.Form("linkAct")
	linkJump=Request.Form("linkJump")
	linkNum=Request.Form("linkNum")
	linkShort=Request.Form("linkShort")
	linkHide=Request.Form("linkHide")
	linkDelete=Request.Form("linkDelete")
	
	if linkStyle<>"1" then linkStyle = 0
	if linkJump<>"1" then linkJump = 0
	if linkAct<>"0" then linkAct = 1
	if linkNum="" or IsNumeric(linkNum)=False then linkNum = 30
	if linkNum>100 then linkNum=100
	if linkShort="" or IsNumeric(linkShort)=False then linkShort = 2
	if linkShort>4 then linkShort=4
	if linkHide="" or IsNumeric(linkHide)=False then linkHide = 10
	if linkHide>3000 then linkHide=3000
	if linkDelete="" or IsNumeric(linkDelete)=False then linkDelete = 500
	if linkDelete>3000 then linkDelete=3000

	' Dim sid_
	' sid_ = Request.Form("bbsSid")
	' If sid_ <> "" And ifLetter(sid_)=False Then Call Error("<card title='出错'><p>论坛会话标识无效！")
	' if len(Request.Form("numTitle"))<1 then
		' Call Error("<card title='出错'><p>请输入！")
	' end if
	'----------------------------------------------------------------
	'	生成link.asp文件
	'----------------------------------------------------------------
	dim HU_Config,HU_File

	HU_File= "../../config/link.asp"'生成link.asp文件路径

	HU_Config="<"&"%"
	HU_Config=HU_Config+chr(13)&chr(10)&"linkStyle="""&linkStyle&""" '友链首页排版"
	HU_Config=HU_Config+chr(13)&chr(10)&"linkAct="""&linkAct&""" '友链审核设置"
	HU_Config=HU_Config+chr(13)&chr(10)&"linkJump="""&linkJump&""" '友链跳转方式"
	HU_Config=HU_Config+chr(13)&chr(10)&"linkNum="""&linkNum&""" '友链每页显示条数"
	HU_Config=HU_Config+chr(13)&chr(10)&"linkShort="""&linkShort&""" '友链简称字数"
	HU_Config=HU_Config+chr(13)&chr(10)&"linkHide="""&linkHide&""" '无链入自动隐藏天数"
	HU_Config=HU_Config+chr(13)&chr(10)&"linkDelete="""&linkDelete&""" '无链入自动删除天数"
	HU_Config=HU_Config+chr(13)&chr(10)&"%"&">"
	Call savetofile(HU_Config,HU_File)
	Response.Write "<card id='card2' title='正在返回' ontimer='index.asp?sid="&sid&"'><timer value='10'/><p>"
	Response.Write "成功设置！正在返回..."
else
	if linkStyle<>"1" then linkStyle = 0
	if linkJump<>"1" then linkJump = 0
	if linkAct<>"0" then linkAct = 1
	if linkNum="" or IsNumeric(linkNum)=False then linkNum = 30
	if linkShort="" or IsNumeric(linkShort)=False then linkShort = 2
	if linkShort>4 then linkShort=4
	if linkHide="" or IsNumeric(linkHide)=False then linkHide = 10
	if linkDelete="" or IsNumeric(linkDelete)=False then linkDelete = 500

%>
<card id="index" title="网站友链配置">
<p align="left">
友链首页排版:<br/> 
<select name="linkStyle<%=time_r%>" value="<%=linkStyle%>">
<option value="0">横排经典</option>
<option value="1">简单分类</option>
</select><br/>
审核设置:<br/> 
<select name="linkAct<%=time_r%>" value="<%=linkAct%>">
<option value="1">必须审核</option>
<option value="0">不用审核</option>
</select><br/>
跳转方式:<br/> 
<select name="linkJump<%=time_r%>" value="<%=linkJump%>">
<option value="0">二次跳转</option>
<option value="1">直接跳转</option>
</select><br/>
友链每页显示条数:<br/>
<input name="linkNum<%=time_r%>" type="text" value="<%=linkNum%>" size="2"/><br/>
友链简称字数:<br/>
<input name="linkShort<%=time_r%>" type="text" value="<%=linkShort%>" size="2"/><br/>
无链入自动隐藏天数:<br/>
<input name="linkHide<%=time_r%>" type="text" value="<%=linkHide%>" size="2"/><br/>
无链入自动删除天数:<br/>
<input name="linkDelete<%=time_r%>" type="text" value="<%=linkDelete%>" size="2"/><br/>
<anchor>保存配置
<go href="link.asp?submit=true&amp;sid=<%=sid%>" method="post">
<postfield name="linkStyle" value="$(linkStyle<%=time_r%>)" />
<postfield name="linkAct" value="$(linkAct<%=time_r%>)"/>
<postfield name="linkJump" value="$(linkJump<%=time_r%>)"/>
<postfield name="linkShort" value="$(linkShort<%=time_r%>)"/>
<postfield name="linkHide" value="$(linkHide<%=time_r%>)" />
<postfield name="linkDelete" value="$(linkDelete<%=time_r%>)" />
<postfield name="linkNum" value="$(linkNum<%=time_r%>)" />
</go></anchor><br/>
温馨提示:<br/>
1、简称字数不能超过4，会影响排版<br/>
<%end if%><br/>
<a href="index.asp?sid=<%=sid%>">[网站配置]</a><%call Last%>